home *** CD-ROM | disk | FTP | other *** search
- #! /bin/sh
- # Shell file to convert various formats to Mif
- # $Id: MifRead,v 1.2 92/11/17 21:58:23 connolly Exp $
- #
- # Edit as needed to execute other filters;
- # The cases below should match the contents of file .fminit2.0/suffixlist
- #
- # Three filters are provided with standard Maker: One reads files with the
- # suffix ".txtalt" and converts them to mif, attempting to recognize paragraphs.
- # The second reads and converts MML files. See the Reference Manual for
- # more information. The third filter converts old format documents into
- # mif so they can be read by FrameMaker 3.0.
- #
- # Inputs are:
- # $1 = input file to be filtered (full path, example: /usr/drf/foo.bar )
- # $2 = output file from filter (full path, example: /usr/drf/foo.tmp )
- # $3 = input file's path ( example: /usr/drf )
- # $4 = .fminit2.0's directory
- # $5 = maker's bin directory
- #
- # See what the file type is, and run the appropriate program
- case $1 in
- *.is1) $5/is1tomif <$1 >$2;;
- *.rm8) $5/rm8tomif <$1 >$2;;
- *.txtalt) $5/txttomif <$1 >$2;;
- *.mml|*.framemml) $5/mmltomif -I$3 -I~ -I$4 <$1 >$2;;
- *#D13)
- # This is a fake suffix for Maker's use.
- # dr=`expr "$1" : '\(.*\)#D13'` #-- expr loses if $1 long
- dr=`echo "$1" | sed 's/#D13$//'`
- $5/1.3binarytomif "$dr" "$2"
- ;;
- *.m) $5/trofftomif <$1 >$2;;
- *.man) $5/trofftomif -man <$1 >$2;;
- *.1) $5/trofftomif -man <$1 >$2;;
- *.2) $5/trofftomif -man <$1 >$2;;
- *.3) $5/trofftomif -man <$1 >$2;;
- *.4) $5/trofftomif -man <$1 >$2;;
- *.5) $5/trofftomif -man <$1 >$2;;
- *.6) $5/trofftomif -man <$1 >$2;;
- *.7) $5/trofftomif -man <$1 >$2;;
- *.8) $5/trofftomif -man <$1 >$2;;
- *.me) $5/trofftomif -me <$1 >$2;;
- *.ms) $5/trofftomif -ms <$1 >$2;;
- *.dca) $5/dcatomif <$1 >$2;;
- *.rft) $5/dcatomif <$1 >$2;;
- *.iaf) $5/iaftomif <$1 >$2;;
- *.wp) $5/wptomif <$1 >$2;;
- *.cgm) $5/cgmtomif <$1 >$2;;
- *.c960) $5/c960tomif <$1 >$2;;
- *.cc) $5/c960tomif <$1 >$2;;
- *.dxf) $5/dxftomif <$1 >$2;;
- *.hpgl) $5/hpgltomif <$1 >$2;;
- *.iges) $5/igestomif <$1 >$2;;
- *.igs) $5/igestomif <$1 >$2;;
- *.w3) $5/wordtomif <$1 >$2;;
- *.w4) $5/wordtomif <$1 >$2;;
- *.msw) $5/wordtomif <$1 >$2;;
- *.pct) $5/picttomif <$1 >$2;;
- *.html) echo converting html file: $1
- fix-html.pl $1 >/tmp/mifread.$$.sgml
- sgmls html.dtd /tmp/mifread.$$.sgml | xlisp html2mml.l \
- | $5/mmltomif -I$3 -I~ -I$4 >$2
- #@@ rm /tmp/mifread.$$.sgml
- ;;
- esac
-